﻿@using InnovaApp.Portals.MVC4Portal.Models.MetaModels.OrderManagement
@using InnovaApp.Layers.ResourcesLayer.Properties
@model InnovaApp.Portals.MVC4Portal.Models.MetaModels.OrderManagement.OrderDetail_MetaModel
<tr>
    <td class="quantity">
        @Html.TextBoxFor(m => m.Quantity, new { @class = "calculateOnChange rounded4 number" })
    </td>
    <td class="product">
        @Html.DropDownListFor(m => m.FK_Product, Model.Products, new { @class = "ddlProducts calculateOnChange", @initValue = Model.FK_Product })
    </td>
    <td class="productDescription">
        @Html.TextBoxFor(m => m.ProductDescription, new { @readonly = "readonly", @class = "readonly rounded4" })
    </td>
    <td class="unitPrice">
        @Html.TextBoxFor(m => m.UnitPrice, new { @readonly = "readonly", @class = "readonly rounded4 number" })
    </td>
    <td class="totalPrice">
        @Html.TextBoxFor(m => m.TotalPrice, new { @readonly = "readonly", @class = "readonly rounded4 number" })
    </td>
    <td class="appliedVATRate">
        @Html.TextBoxFor(m => m.AppliedVATRate, new { @readonly = "readonly", @class = "readonly rounded4 number" })
    </td>
    <td class="vatTotal">
        @Html.TextBoxFor(m => m.VatTotal, new { @readonly = "readonly", @class = "readonly rounded4 number" })
    </td>
    <td class="allTaxeIncludedTotal">
        @Html.TextBoxFor(m => m.AllTaxeIncludedTotal, new { @readonly = "readonly", @class = "readonly rounded4 number" })
    </td>
    @{
		string classToAdd = string.Empty;
		if (Model.RowMode == OrderDetail_MetaModel.enOrderDetailRowMode.Add)
		{
			classToAdd = "submitAddRow ui-icon-plusthick";
		}
		else {
			classToAdd = "submitRemoveRow ui-icon-minusthick";
		}
    }
    <td>
        <input type="submit" value="@Model.AddRemoveButtonCaption" class="@classToAdd cmdAddUpdate rowButton"/>
        @Html.HiddenFor(m => m.Id)
    </td>
</tr>
